﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml.Linq;

namespace WindowsPhone.Marketplace
{

    /// <summary>
    /// Miscellaneous configuration options that determine where and how the marketplace
    /// feeds are pulled. Modify at your own peril! :)
    /// </summary>
    public class MarketplaceSettings
    {
        public string BaseAppsUrl { get; set; }
        public string BaseImageUrl { get; set; }

        public string ZestVersion { get; set; }
        public string ZestImageVersion { get; set; }

        public static XNamespace AtomNamespace = "http://www.w3.org/2005/Atom";
        public static XNamespace ZestNamespace = "http://schemas.zune.net/catalog/apps/2008/02";

        public string BaseApps { get; set; }
        public string BaseImage { get; set; }

        public string BaseAppsResource { get; set; }
        public string BaseCommentsResource { get; set; }
        public string BaseImageResource { get; set; }

        public MarketplaceSettings()
        {
            BaseAppsUrl = "http://catalog.zune.net";
            BaseImageUrl = "http://image.catalog.zune.net";

            ZestVersion = "/v3.2/";
            ZestImageVersion = "/v3.0/";

            BaseApps = "apps/";
            BaseImage = "image/";

            BaseAppsResource = "?clientType=WinMobile%207.1&store=Zest&orderby=downloadRank";
            BaseCommentsResource = "/reviews/?store=Zest&chunkSize=10";
            BaseImageResource = "?width=240&height=240";

        }
    }
}
